#coding=utf-8
from urllib import request
import re
import os
import urllib
from os.path import join

url=r'http://www.douban.com/'
webPage=urllib.request.urlopen(url)
html=webPage.read()
# gbkTypeStr = html.encode("GBK", 'ignore');
data=html.decode('gbk','ignore')
print(data)
print(type(webPage))
print(webPage.geturl())
print(webPage.info())
print(webPage.getcode())
